﻿using System;

public partial class System_Controls_Common_CodeEditor : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack) 
        {
            if (Request.QueryString["FilePath"] != null) 
            {
                hf_Path.Value = Request.QueryString["FilePath"].ToString();
                tb_Value.Text = SiteFox.Business.Logic.FileManager.ReadFileSource(hf_Path.Value);
            }
        }
    }
    protected void lib_Save_Click(object sender, EventArgs e)
    {
        SiteFox.Business.Logic.FileManager.WriteFileSource(hf_Path.Value, tb_Value.Text);
        ucc_MessageText.Value = Resources.dcCommon.dc_DataSuccessfullySaved;
    }
}